When a user contacts a site over the Internet, there are a number of situations in which the site (the web server) has a need or interest in collecting information from the user. Such information can be, for example, for (1) registering for a service when the server wants to collect and maintain a record of registered users (whether for paying memberships or not), (2) entering information to access a service, such as a mortgage calculator, or (3) entering ordering information, such as a book seller wanting to have a user enter his or her name, address, and credit card number.
Referring to FIG. 1, a server 10 communicates with a user/client 12 over the Internet with a hypertext application, where “hypertext” refers to the ability to link one document to another. This application, such as a World Wide Web (web) application, can include one or more hypertext documents 14 that are provided to clients and that have input fields so that the user can fill in and submit input field data back to hypertext server 10. The submitted input field data is then processed by a software component 16 that receives the data and takes actions appropriate to the application. For example, in the example of a user entering his or her name and address to order books, the software component converts each address field to a correct data type, and executes the desired functionality to complete the purchase.
Hypertext documents are typically written in HyperText Markup Language (HTML), which uses tags to identify components and actions, such as <p> for new paragraph or <A HREF=“document.html”> to create a link to another document. Textual input fields are designated by <INPUT> tags. Each of the input fields is given a name by the author of the hypertext document. For example, an input field for the book buyer's last name might be named “LAST_NAME,” whereas the zip code might be named “ZIP_CODE.” A common technique for processing such input data is to create a software component that is specialized for each individual hypertext document, such as a component designed to receive a book order. The software component parses the submitted data to search for the input fields with the appropriate names as such names have been programmed in the software component. If the correctly named input field is found, the component must further convert the submitted data in the input field to the correct data type. Thus the component designed to process the book purchase document would parse the input and search for a field named “LAST_NAME” and a field named “ZIP_CODE” as well as all of the other required fields. If these input fields are found, the data must be converted to the correct data type; for example, the “ZIP_CODE” data must be converted from text to an integer. The component can also determine if the form is correct, e.g., check to make sure that “ZIP_CODE” has five or nine numbers for a United States zip code.
Because the hypertext document is created and maintained separately from the software component that receives the input data (even though the two are associated with each other), the names of the input fields must be carefully maintained in the document and the component to correspond to each other. If the input field for the buyer's last name were misspelled in the hypertext document as “LST_NAME” (as shown in FIG. 1), the specialized software component would not find the input field, as it would be looking for “LAST_NAME.” Furthermore, the software component must encode the correct data types of each input field, and this information must be coded for each such component and field. The component must encode, for example, the fact that the input field for the buyer's zip code must be converted to an integer and must handle various types of conversion errors.
Such an application is difficult to develop and maintain, as it is easy to introduce naming and type conversion errors as the hypertext documents and software components are separately modified. Furthermore, because the software components encode the specific names and types of each input field, each component is specialized for a particular hypertext document, and not practicably re-usable for other documents or applications.